<#include "/macro.include"/>
<#assign className = table.className>
<#assign classNameLower = className?uncap_first>
[#include "/admin/common/head.ftl"]

<div class="page-header">
    <h1> ${className}管理 <small> <i class="ace-icon fa fa-angle-double-right"></i> [#if formType == "insert"]添加[#elseif formType == "update"]修改[/#if] </small> </h1>
</div>

<!--begin main-content -->
<div class="main-content">

    <!-- page-content start-->
    <div class="page-content">

        <div class="row">
            <div class="col-xs-12">
                <div id="wizard" class="content-wizard">
                    <div class="stepContainer">
                        <form id="putFormId" action="[#if formType == "insert"]save.jhtml[#elseif formType == "update"]edit.jhtml[/#if]" method="post">
                            <input type="hidden" name="id" value="<#list table.compositeIdColumns as column><@jspEl "${classNameLower}.${column.columnNameFirstLower}" /></#list>">
                            <table class="table table-bordered table-striped formLayout m0">
                                <colgroup>
                                    <col width="15%">
                                    <col width="35%">
                                    <col width="15%">
                                    <col width="35%">
                                </colgroup>
                                <tbody>
                                <#list table.notPkColumns as column>
                                <tr>
                                    <td class="textL w110">
                                        <label class="necessary">${column.columnNameLower}</label>
                                    </td>
                                    <td class="textL" colspan="3">
                                        <input type="text" name="${column.columnNameLower}" value="<@jspEl "${classNameLower}.${column.columnNameFirstLower}"/>" class="col-xs-3" aria-required="true">
                                    </td>
                                </tr>
                                </#list>
                                </tbody>
                            </table>
                        </form>
                    </div>
                </div>
                <div class="actionBar">
                    <a id="submitForm" href="javascript:void(0);" class="btn btn-primary btn-xs mr5 pull-right" style="margin-left: 5px">保存</a>
                    <a id="resetForm" href="javascript:void(0);" class="btn btn-primary btn-xs mr5 pull-right">重置</a>
                </div><!-- page-content end-->
            </div><!-- end main-content -->
        </div>
    </div>
</div>

<script src="/resources/admin/js/moudle/${classNameLower}.js"></script>
[#include "/admin/common/bottom.ftl"]